<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>

        .box{
            text-align: center;
            width: 300px;
            height: 500px;
            background-color: pink;
            margin: auto;
        }
        .sub .box{
            text-align: center;
            left: 50px;
            margin: auto;
        }
    </style>
</head>
<body>
    <form th:action="@{/}" method="post" class="box">
        <table>
            <caption>注册页面</caption>
            <tr class="input-box">
                <td>用户名:</td>
                <td><input type="text" name="username"></td>
            </tr>
            <tr class="input-box">
                <td>密码:</td>
                <td><input type="password"  name="password"></td>
            </tr>
            <input type="hidden" name="rid" value="1">
            <tr>
                <td><input class="sub" type="submit" value="register"></td>
            </tr>
            <tr>
                <td><span th:text="${msg}"></span></td>
            </tr>
        </table>

</form>

</body>
</html>